import service from "@/utils/require";

const before = "/api";

export function getFileList(data: any) {
  const request = service({
    url: before + "/getDataListByCate",
    method: "get",
    params: data,
  });

  return request;
}
export function getFile(data: any, ContentType = "") {
  const request = service({
    url: before + "/getFile",
    method: "get",
    params: data,
    responseType: "blob",
  });

  return request;
}
export function update(data: any) {
  const request = service({
    url: before + "/update",
    method: "post",
    data: data,
  });

  return request;
}
export function del(data: any) {
  const request = service({
    url: before + "/del",
    method: "post",
    data: data,
  });

  return request;
}

export function getLog(data: any) {
  const request = service({
    url: before + "/getLog",
    method: "get",
    params: data,
  });

  return request;
}
export function getUser(data: any) {
  const request = service({
    url: before + "/getUser",
    method: "get",
    params: data,
  });

  return request;
}
